{% load staticfiles %}
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>{% block title %}{% endblock %}</title>
  <!-- Tell the browser to be responsive to screen width -->
  <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
  <!-- Bootstrap 3.3.7 -->
  <link rel="stylesheet" href="{% static 'bower_components/bootstrap/dist/css/bootstrap.min.css' %}">
  <!-- Font Awesome -->
  <link rel="stylesheet" href="{% static 'bower_components/font-awesome/css/font-awesome.min.css' %}">
  <!-- Ionicons -->
  <link rel="stylesheet" href="{% static 'bower_components/Ionicons/css/ionicons.min.css' %}">
  <!-- Theme style -->
  <link rel="stylesheet" href="{% static 'dist/css/AdminLTE.min.css' %}">
  <!-- AdminLTE Skins. Choose a skin from the css/skins
       folder instead of downloading all of them to reduce the load. -->
  <link rel="stylesheet" href="{% static 'dist/css/skins/_all-skins.min.css' %}">
  <!-- Morris chart -->
  <link rel="stylesheet" href="{% static 'bower_components/morris.js/morris.css' %}">
  <!-- jvectormap -->
  <link rel="stylesheet" href="{% static 'bower_components/jvectormap/jquery-jvectormap.css' %}">
  <!-- Date Picker -->
  <link rel="stylesheet" href="{% static 'bower_components/bootstrap-datepicker/dist/css/bootstrap-datepicker.min.css' %}">
  <!-- Daterange picker -->
  <link rel="stylesheet" href="{% static 'bower_components/bootstrap-daterangepicker/daterangepicker.css' %}">
  <!-- bootstrap wysihtml5 - text editor -->
  <link rel="stylesheet" href="{% static 'plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.min.css' %}">

  <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
  <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
  <!--[if lt IE 9]>
  <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
  <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
  <![endif]-->

  <!-- Google Font -->
  <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700,300italic,400italic,600italic">
</head>
<body class="hold-transition skin-blue sidebar-mini">
<div class="wrapper">

  <header class="main-header">
    <!-- Logo -->
    <a href="index2.html" class="logo">
      <!-- mini logo for sidebar mini 50x50 pixels -->
      <span class="logo-mini"><b>C</b>O</span>
      <!-- logo for regular state and mobile devices -->
      <span class="logo-lg"><b>箱箱共用</b></span>
    </a>
    <!-- Header Navbar: style can be found in header.less -->
    <nav class="navbar navbar-static-top">
      <!-- Sidebar toggle button-->
      <a href="#" class="sidebar-toggle" data-toggle="push-menu" role="button">
        <span class="sr-only">Toggle navigation</span>
      </a>

      <div class="navbar-custom-menu">
        <ul class="nav navbar-nav">
          <!-- User Account: style can be found in dropdown.less -->
          <li class="dropdown user user-menu">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
              <img src="{% static 'images/user/box.png' %}" class="user-image" alt="User Image">
              <span class="hidden-xs" id="view_username">{{username}}</span>
            </a>
            <ul class="dropdown-menu">
              <!-- User image -->
              <li class="user-header">
                <img src="{% static 'images/user/box.png' %}" class="img-circle" alt="User Image">

                <p>
                    Web Developer by qiubaolin
                    email:1091897593@qq.com
                  <small>2018/10/19</small>
                </p>
              </li>
              <!-- Menu Footer-->
              <li class="user-footer">
                <div class="pull-left">
                  <a href="/chpasswd/" class="btn btn-default btn-flat">修改密码</a>
                </div>
                <div class="pull-right">
                  <a href="/logout/" class="btn btn-default btn-flat">注销</a>
                </div>
              </li>
            </ul>
          </li>
        </ul>
      </div>
    </nav>
  </header>
  <!-- Left side column. contains the logo and sidebar -->
  <aside class="main-sidebar">
    <!-- sidebar: style can be found in sidebar.less -->
    <section class="sidebar">
      <!-- search form -->
      <form action="#" method="get" class="sidebar-form">
        <div class="input-group">
          <input type="text" name="q" class="form-control" placeholder="Search...">
          <span class="input-group-btn">
                <button type="submit" name="search" id="search-btn" class="btn btn-flat"><i class="fa fa-search"></i>
                </button>
              </span>
        </div>
      </form>
      <!-- /.search form -->
      <!-- sidebar menu: : style can be found in sidebar.less -->
      <ul class="sidebar-menu" data-widget="tree">
        <li class="header " style="color:white">配置管理列表</li>
        <li><a href="/index/"><i class="fa fa-home"></i> <span>首页</span></a></li>
        <li class="treeview">
          <a href="#">
            <i class="fa fa-share"></i> <span>站点导航</span>
            <span class="pull-right-container">
              <i class="fa fa-angle-left pull-right"></i>
            </span>
          </a>
          <ul class="treeview-menu">
            <li><a href="/website/addweb/"><i class="fa fa-circle-o"></i>添加站点</a></li>
            <li><a href="/website/manageweb/"><i class="fa fa-circle-o"></i>站点管理</a></li>
          </ul>
        </li>
        <li class="treeview">
          <a href="#">
            <i class="fa fa-files-o"></i> <span>环境配置</span>
            <span class="pull-right-container">
              <i class="fa fa-angle-left pull-right"></i>
            </span>
          </a>
          <ul class="treeview-menu">
            <li><a href="/scm/addinfo/"><i class="fa fa-circle-o"></i>添加配置</a></li>
            <li><a href="/scm/manageinfo/"><i class="fa fa-circle-o"></i>配置管理</a></li>
          </ul>
        </li>
        <li onclick="perimission()"><a href="#"><i class="fa fa-retweet"></i> <span >持续集成</span></a></li>
        <li onclick="perimission()"><a href=""><i class="fa fa-repeat"></i> <span>持续交付</span></a></li>
        <li onclick="perimission()"><a href=""><i class="fa fa-television"></i> <span>监控平台</span></a></li>
        <li onclick="perimission()"><a href=""><i class="fa fa-book"></i> <span>文件管理</span></a></li>
        <li><a href="/users/manageuser/"><i class="fa fa-group"></i> <span>用户管理</span></a></li>
      </ul>
    </section>
    <!-- /.sidebar -->
  </aside>

  <!-- Content Wrapper. Contains page content -->
  <div class="content-wrapper">
    <div class="box-body">
        {% block content %}{% endblock %}
    </div>
  </div>
  </aside>
</div>
<!-- ./wrapper -->

<!-- jQuery 3 -->
<script src="{% static 'bower_components/jquery/dist/jquery.js' %}"></script>
<script src="{% static 'bower_components/jquery/dist/jquery.min.js' %}"></script>
<!-- jQuery UI 1.11.4 -->
<script src="{% static 'bower_components/jquery-ui/jquery-ui.min.js' %}"></script>
<!-- Resolve conflict in jQuery UI tooltip with Bootstrap tooltip -->
<script>
  $.widget.bridge('uibutton', $.ui.button);
</script>
<!-- Bootstrap 3.3.7 -->
<script src="{% static 'bower_components/bootstrap/dist/js/bootstrap.min.js' %}"></script>
<!--layer-->
<script src="{% static 'layer/layer.js' %}"></script>

<!-- Morris.js charts
<script src="{% static 'bower_components/raphael/raphael.min.js' %}"></script>
<script src="{% static 'bower_components/morris.js/morris.min.js' %}"></script>
-->
<!-- Sparkline
<script src="{% static 'bower_components/jquery-sparkline/dist/jquery.sparkline.min.js' %}"></script>
-->
<!-- jvectormap
<script src="{% static 'plugins/jvectormap/jquery-jvectormap-1.2.2.min.js' %}"></script>
<script src="{% static 'plugins/jvectormap/jquery-jvectormap-world-mill-en.js' %}"></script>
 -->
<!-- jQuery Knob Chart
<script src="{% static 'bower_components/jquery-knob/dist/jquery.knob.min.js' %}"></script>
 -->
<!-- daterangepicker
<script src="{% static 'bower_components/moment/min/moment.min.js' %}"></script>
<script src="{% static 'bower_components/bootstrap-daterangepicker/daterangepicker.js' %}"></script>
 -->
<!-- datepicker
<script src="{% static 'bower_components/bootstrap-datepicker/dist/js/bootstrap-datepicker.min.js' %}"></script>
-->
<!-- Bootstrap WYSIHTML5
<script src="{% static 'plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.min.js' %}"></script>
 -->
<!-- Slimscroll
<script src="{% static 'bower_components/jquery-slimscroll/jquery.slimscroll.min.js' %}"></script>
 -->
<!-- FastClick
<script src="{% static 'bower_components/fastclick/lib/fastclick.js' %}"></script>
 -->
<!-- AdminLTE App -->
<script src="{% static 'dist/js/adminlte.min.js' %}"></script>

<!-- AdminLTE dashboard demo (This is only for demo purposes)
<script src="{% static 'dist/js/pages/dashboard.js' %}"></script>
-->
<!-- AdminLTE for demo purposes
<script src="{% static 'dist/js/demo.js' %}"></script>
 -->
<script>
    function perimission(){
        if( $("#view_username").text() != "admin"){
                  alert("您无权限操作！")
        }else{
            alert("虽然您是超级管理员，但是此功能还没开发完也无法使用！")
        }
    }
</script>
{% block script %}
{% endblock %}
</body>
</html>